from django.urls import path
from rest_framework.routers import DefaultRouter  # DefaultRouter 比 SimpleRouter 多一个登录接口

from work.views import *

urlpatterns = [

]
router = DefaultRouter()  # 拿到方法
router.register('label', LabelViewSet)  # lable 自定义路由路径
router.register('topics', TopicViewSet)
router.register('topicstu', TopicStudentViewSet)
# 已自动生成五个接口
urlpatterns += router.urls
